const menuAgent = require('@/assets/img/icon/menu_agent.png');
const menuScene = require('@/assets/img/icon/menu_scene.png');
const menuWorkDay = require('@/assets/img/icon/menu_work_day.png');
const menuWorkTime = require('@/assets/img/icon/menu_work_time.png');
const menuAccount = require('@/assets/img/icon/menu_account.png');
const menuCallRules = require('@/assets/img/icon/menu_call_rules.png');
const menuForm = require('@/assets/img/icon/menu_form.png');
const menuSessions = require('@/assets/img/icon/menu_session.png');
const menuRec = require('@/assets/img/icon/menu_rec.png');
const menuGroup = require('@/assets/img/icon/menu_group.png');
const menuSystem = require('@/assets/img/icon/system.png');
const menuDailyRecord = require('@/assets/img/icon/dailyRecord_icon.png');
const menuBlacklist = require('@/assets/img/icon/blacklist.png');
const menuKb = require('@/assets/img/icon/kb.png');

const routes = [
	{
		path: '*',
		name: '404',
		component: () => import('@/views/components/404.vue')
	},
	{ path: '/', redirect: '/login' },
	{ path: '/account', name: 'account', component: () => import('@/views/Login/AccountLogin.vue') },
	{ path: '/workbench', name: 'workbench', component: () => import('@/views/Workbench/index.vue') },
	{
		path: '/index',
		name: 'index',
		component: () => import('../views/Index.vue'),
		children: [
			{
				path: '/index/home',
				name: 'home',
				component: () => import('@/views/Home/Home.vue'),
				meta: { title: '首页', type: '', keepAlive: true, jumpNo: 0, toPath: '/index/home' }
			},
			{
				path: '/index/sessions',
				name: 'sessions',
				component: () => import('@/views/Sessions/Sessions.vue'),
				meta: { title: '会话管理', icon: menuSessions, keepAlive: true, jumpNo: 1, toPath: '/index/sessions/sessionRecord' },
				children: [
					{
						path: '/index/sessions/sessionStatistics',
						name: 'sessionStatistics',
						component: () => import('@/views/Sessions/SessionStatistics.vue'),
						meta: { title: '会话统计', icon: '', keepAlive: false, jumpNo: 22, toPath: '/index/sessions/sessionStatistics' }
					},
					{
						path: '/index/sessions/sessionRecord',
						name: 'sessionRecord',
						component: () => import('@/views/Sessions/SessionRecord.vue'),
						meta: { title: '会话记录', icon: '', keepAlive: false, jumpNo: 23, toPath: '/index/sessions/sessionRecord' }
					}
				]
			},
			{
				path: '/index/quality',
				name: 'quality',
				component: () => import('@/views/QualityInspection/QualityInspection.vue'),
				meta: { title: '业务记录管理', icon: menuSessions, keepAlive: false, jumpNo: 18, toPath: '/index/quality' }
			},
			{
				path: '/index/agent',
				name: 'agent',
				component: () => import('@/views/Agent/Agent.vue'),
				meta: { title: '坐席管理', icon: menuAgent, keepAlive: false, jumpNo: 2, toPath: '/index/agent' }
			},
			{
				path: '/index/account',
				name: 'account',
				component: () => import('@/views/Account/Account.vue'),
				meta: { title: '账号管理', icon: menuAccount, keepAlive: false, jumpNo: 3, toPath: '/index/account' }
			},
			{
				path: '/index/group',
				name: 'group',
				component: () => import('@/views/Group/Group.vue'),
				meta: { title: '分组管理', icon: menuGroup, keepAlive: false, jumpNo: 4, toPath: '/index/group' }
			},
			{
				path: '/index/labels',
				name: 'labels',
				component: () => import('../views/Labels/LabelsManager.vue'),
				meta: { title: '标签管理', icon: menuScene, keepAlive: false, jumpNo: 34, toPath: '/index/labels' }
			},
			{
				path: '/index/form',
				name: 'form',
				component: () => import('@/views/Form/Form.vue'),
				meta: { title: '表单管理', icon: menuForm, keepAlive: false, jumpNo: 5, toPath: '/index/form' }
			},
			{
				path: '/index/form/:id',
				name: 'settingform',
				component: () => import('../views/Form/SettingForm.vue'),
				meta: { title: '', type: '', keepAlive: false, jumpNo: 16, toPath: '/index/form' }
			},
			{
				path: '/index/session',
				name: 'session',
				component: () => import('../views/Sessions/SessionInfo.vue'),
				meta: { title: '', type: '', keepAlive: false, jumpNo: 9, toPath: '/index/session' }
			},
			{
				path: '/index/jmgk',
				name: 'jmgk',
				component: () => import('../views/Sessions/Jmgk.vue'),
				meta: { title: '', type: '', keepAlive: false, jumpNo: 10, toPath: '/index/jmgk' }
			},
			{
				path: '/index/newFlow/:id',
				name: 'newFlow',
				component: () => import('../views/AiWorkFlow/NewAiWorkFlow.vue'),
				meta: { title: '', type: '', keepAlive: false, jumpNo: 11, toPath: '/index/newFlow' }
			},
			{
				path: '/index/scene',
				name: 'scene',
				component: () => import('../views/Scene/Scene.vue'),
				meta: { title: '业务场景管理', icon: menuScene, keepAlive: false, jumpNo: 12, toPath: '/index/scene' }
			},
			{
				path: '/index/scene/sceneInfo/:id',
				name: 'sceneInfo',
				component: () => import('../views/Scene/SceneInfo.vue'),
				meta: { title: '', type: '', keepAlive: false, jumpNo: 13, toPath: '/index/scene/sceneInfo' }
			},

			{
				path: '/index/work',
				name: 'work',
				meta: { title: '通话规则', icon: menuCallRules, keepAlive: true, jumpNo: 14, toPath: '/index/work' },
				component: () => import('../views/Work/Work.vue'),
				children: [
					{
						path: '/index/work/workingtime',
						name: 'workingtime',
						component: () => import('../views/Work/WorkingTime.vue'),
						meta: { title: '工作时间规则', icon: menuWorkTime, keepAlive: false, jumpNo: 15, toPath: '/index/work/workingtime' }
					},
					{
						path: '/index/work/workingday',
						name: 'workingday',
						component: () => import('../views/Work/WorkingDay.vue'),
						meta: { title: '工作日规则', icon: menuWorkDay, keepAlive: false, jumpNo: 16, toPath: '/index/work/workingday' }
					}
				]
			},
			{
				path: '/index/system',
				name: 'system',
				component: () => import('@/views/SystemSettings/SystemSettings.vue'),
				meta: { title: '系统配置', icon: menuSystem, keepAlive: false, jumpNo: 17, toPath: '/index/system' }
			},
			{
				path: '/index/quality/inspection',
				name: 'inspection',
				component: () => import('@/views/QualityInspection/Inspection.vue'),
				meta: { title: '', type: '', keepAlive: false, jumpNo: 19, toPath: '/index/quality/inspection' }
			},
			{
				path: '/index/scene/deposition/:id',
				name: 'deposition',
				component: () => import('../views/Scene/Deposition/index.vue'),
				meta: { title: '', type: '', keepAlive: false, jumpNo: 20, toPath: '/index/scene/deposition' }
			},
			{
				path: '/index/scene/variables/:id',
				name: 'variables',
				component: () => import('../views/Variables/SceneVariables.vue'),
				meta: { title: '', type: '', keepAlive: false, jumpNo: 21, toPath: '/index/scene/variables' }
			},
			{
				path: '/index/scene/realQuality/:id',
				name: 'realQuality',
				component: () => import('../views/Scene/RealtimeQuality.vue'),
				meta: { title: '', type: '', keepAlive: false, jumpNo: 23, toPath: '/index/scene/realQuality' }
			},
			{
				path: '/index/dailyRecord',
				name: 'dailyRecord',
				meta: { title: '日志', icon: menuDailyRecord, keepAlive: true, jumpNo: 24, toPath: '/index/dailyRecord' },
				component: () => import('../views/DailyRecord/index.vue'),
				children: [
					{
						path: '/index/dailyRecord/operation',
						name: 'operation',
						component: () => import('../views/DailyRecord/Operation.vue'),
						meta: { title: '运管操作日志', icon: '', keepAlive: false, jumpNo: 25, toPath: '/index/dailyRecord/operation' }
					},
					{
						path: '/index/dailyRecord/agentStatus',
						name: 'agentStatus',
						component: () => import('../views/DailyRecord/AgentStatus.vue'),
						meta: { title: '坐席状态日志', icon: '', keepAlive: false, jumpNo: 26, toPath: '/index/dailyRecord/agentStatus' }
					}
				]
			},
			{
				path: '/index/role',
				name: 'role',
				meta: { title: '账号及权限', icon: menuAccount, keepAlive: true, jumpNo: 27, toPath: '/index/role' },
				component: () => import('@/views/AccountPermissions/Role.vue'),
				children: [
					{
						path: '/index/role/management',
						name: 'management',
						component: () => import('@/views/AccountPermissions/Manament/AccountManagement.vue'),
						meta: { title: '账号管理', keepAlive: false, jumpNo: 28, toPath: '/index/role/management' }
					},
					{
						path: '/index/role/permission',
						name: 'permission',
						component: () => import('@/views/AccountPermissions/Permission/RolePermission.vue'),
						meta: { title: '角色权限', keepAlive: false, jumpNo: 29, toPath: '/index/role/permission' }
					}
				]
			},
			{
				path: '/index/blacklist',
				name: 'blacklist',
				meta: {
					title: '黑名单管理', icon: menuBlacklist, keepAlive: true, jumpNo: 30, toPath: '/index/blacklist'
				},
				component: () => import('@/views/Blacklist/BlacklistManagement.vue'),
				children: [
					{
						path: '/index/blacklist/accountManagement',
						name: 'accountManagement',
						component: () => import('@/views/Blacklist/AccountManagement/AccountManagement.vue'),
						meta: { title: '账号管理', keepAlive: false, jumpNo: 31, toPath: '/index/blacklist/accountManagement' }
					},
					{
						path: '/index/blacklist/groupManagement',
						name: 'groupManagement',
						component: () => import('@/views/Blacklist/GroupManagement/GroupManagement.vue'),
						meta: { title: '分组管理', keepAlive: false, jumpNo: 32, toPath: '/index/blacklist/groupManagement' }
					},
					{
						path: '/index/blacklist/callRecord',
						name: 'callRecord',
						component: () => import('@/views/Blacklist/CallRecord/CallRecord.vue'),
						meta: { title: '呼叫记录', keepAlive: false, jumpNo: 33, toPath: '/index/blacklist/callRecord' }
					},
				]
			},
			{
				path: '/index/scene/sceneInfo/:id/bindgroups2scene',
				name: 'bindGroupsToScene',
				component: () => import('../views/Scene/BindGroupsToScene.vue'),
				meta: { title: '绑定分组', type: '', keepAlive: false, jumpNo: 35, toPath: '/index/scence/sceneInfo' }
			},
			{
				path: '/index/scene/businessResources/:id',
				name: 'businessResources',
				component: () => import('../views/Scene/BusinessResources.vue'),
				meta: { title: '', type: '', keepAlive: false, jumpNo: 36, toPath: '/index/scene/businessResources' }
			},
			{
				path: '/index/scene/ttsbroadcast/:id',
				name: 'ttsbroadcast',
				component: () => import('../views/Scene/TtsBroadcast/index.vue'),
				meta: { title: '', type: '', keepAlive: false, jumpNo: 37, toPath: '/index/scene/ttsbroadcast' }
			},
			{
				path: '/index/knowledgeBase',
				name: 'knowledgeBase',
				component: () => import('@/views/KnowledgeBase/Index.vue'),
				meta: { title: '知识库管理', type: '', icon: menuKb, keepAlive: true, jumpNo: 39, toPath: '/index/KnowledgeBase' }
			},
			{
				path: '/index/scene/sessionSummary/:id',
				name: 'sessionSummary',
				component: () => import('../views/Scene/EditSessionSummary.vue'),
				meta: { title: '', type: '', keepAlive: false, jumpNo: 40, toPath: '/index/scene/sessionSummary' }
			},
		]
	},
	{ path: '/login', name: 'login', component: () => import('../views/Login/Login.vue') },
	{ path: '/super', component: () => import('../views/SuperAdmin/SuperLogin.vue') },
	{ path: '/superadmin', component: () => import('../views/SuperAdmin/Super.vue') },
	{
		path: '/flowDetail',
		name: 'flowDetail',
		component: () => import('../views/AiWorkFlow/NewAiWorkFlow.vue')
	}
];

export default routes;
